class MsgOrderDataModel {
  final int code;
  final String msg;
  final MsgOrderListModel data;

  MsgOrderDataModel({
    required this.code,
    required this.msg,
    required this.data,
  });

  factory MsgOrderDataModel.fromJson(Map<String, dynamic> json) {
    return MsgOrderDataModel(
      code: json['code'],
      msg: json['msg'],
      data: MsgOrderListModel.fromJson(json['data']),
    );
  }
}

class MsgOrderListModel {
  final List<RecordsModel> records;

  MsgOrderListModel({required this.records});

  factory MsgOrderListModel.fromJson(Map<String, dynamic> json) {
    var list = json['records'] as List;
    List<RecordsModel> recordsList =
        list.map((i) => RecordsModel.fromJson(i)).toList();
    return MsgOrderListModel(records: recordsList);
  }
}

class RecordsModel {
  final int id;
  final String messageTitle;
  final String messageStartTime;
  final String messageContent;
  final int messageStatus;

  RecordsModel({
    required this.id,
    required this.messageTitle,
    required this.messageStartTime,
    required this.messageContent,
    required this.messageStatus,
  });

  factory RecordsModel.fromJson(Map<String, dynamic> json) {
    return RecordsModel(
      id: json['id'],
      messageTitle: json['messageTitle'],
      messageStartTime: json['messageStartTime'],
      messageContent: json['messageContent'],
      messageStatus: json['messageStatus'],
    );
  }
}

class PhoneCodeModel {
  final int code;
  final String msg;
  final List<String> data;

  PhoneCodeModel({
    required this.code,
    required this.msg,
    required this.data,
  });

  factory PhoneCodeModel.fromJson(Map<String, dynamic> json) {
    return PhoneCodeModel(
      code: json['code'],
      msg: json['msg'],
      data: List<String>.from(json['data']),
    );
  }
}
